DEFINE BUFFER pt FOR pt_mstr.

FOR EACH pt_mstr WHERE INDEX ("FG-A,FG-B",pt_mstr.pt_part_type) > 0 NO-LOCK,
    EACH pt WHERE pt.pt_part = pt_mstr.pt_bom_code EXCLUSIVE-LOCK BREAK BY pt_mstr.pt_bom_code:
    
    IF FIRST-OF (pt_mstr.pt_bom_code) AND pt.pt_part_type = "FG-C" THEN DO:
       DISP pt_mstr.pt_part pt_mstr.pt_part_type pt_mstr.pt_bom_code pt.pt_part_type . 
    END.
END.
